{% extends 'base.html' %}
{%- block css %}
  {{- super() }}
<link rel="stylesheet" href="{{ get_url('_common/jicheng.css') }}">
<link rel="stylesheet" href="{{ get_url('_common/book.css') }}">
<link rel="stylesheet" href="{{ get_url('_common/med.css') }}">
<link rel="stylesheet" href="{{ get_url('_common/formula.css') }}">
{%- endblock css %}
{%- block scripts %}
  {{- super() }}
  {%- if assets.get('hanzi_script_url') %}
<script>
var jchanzi = { conf: { autoProcess: false } };
</script>
<script src="{{ assets.get('hanzi_script_url') }}"></script>
  {%- endif %}
<script src="{{ get_url('_common/common.js') }}"></script>
<script src="{{ get_url('_common/lib/mark.es6.js') }}"></script>
<script src="{{ get_url('_common/jicheng.js') }}"></script>
{%- block scripts_jicheng %}
{%- endblock scripts_jicheng %}
<script>
Object.assign(utils.PAGE_INFO, {
  data_type: {{ info.get('data-type')|tojson|safe }},
  {%- if assets.get('hanzi_fonts') %}
  hanzi_fonts: {{ assets.get('hanzi_fonts')|tojson|safe }},
  {%- endif %}
  {%- if assets.get('google_cse_script_url') %}
  google_cse_script_url: {{ assets.get('google_cse_script_url')|tojson|safe }},
  {%- endif %}
  {%- if assets.get('google_site_search_root') %}
  google_site_search_root: {{ assets.get('google_site_search_root')|tojson|safe }},
  {%- endif %}
  {%- if assets.get('bing_site_search_root') %}
  bing_site_search_root: {{ assets.get('bing_site_search_root')|tojson|safe }},
  {%- endif %}
});
</script>
{%- endblock scripts %}
{%- block panel_opener %}
<div id="page-panel-open-wrapper" hidden>
<a id="page-panel-open" role="button" aria-label="工具欄"></a>
</div>
{%- endblock panel_opener %}
{%- block panel %}
<!-- panel -->
<div id="page-panel" role="dialog" aria-modal="true" aria-label="工具欄" hidden></div>
<!-- /panel -->
{%- endblock panel %}
{%- block body_end %}
<script>
utils.jicheng = new utils.Jicheng();
</script>
{%- endblock body_end %}
